﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"
    CodeFile="AllTasks.aspx.cs" Inherits="Task_AllTasks" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="Server">
    <h2>
        年检任务审核
    </h2>
    <div class="searchcondition">
        <table class="searchtb">
            <tr>
                <td>
                    月份 &nbsp;<asp:DropDownList runat="server" ID="AuditMonth">
                        <asp:ListItem>1</asp:ListItem>
                        <asp:ListItem>2</asp:ListItem>
                        <asp:ListItem>3</asp:ListItem>
                        <asp:ListItem>4</asp:ListItem>
                        <asp:ListItem>5</asp:ListItem>
                        <asp:ListItem>6</asp:ListItem>
                        <asp:ListItem>7</asp:ListItem>
                        <asp:ListItem>8</asp:ListItem>
                        <asp:ListItem>9</asp:ListItem>
                        <asp:ListItem>10</asp:ListItem>
                        <asp:ListItem>11</asp:ListItem>
                        <asp:ListItem>12</asp:ListItem>
                    </asp:DropDownList>
                    &nbsp;<asp:Button runat="server" Text="查询" />
                </td>
            </tr>
        </table>
    </div>
    <asp:ListView ID="ListView1" runat="server" DataSourceID="SqlDataSource1" EnableViewState="False">
        <LayoutTemplate>
            <table class="commongv">
                <tr>
                    <th>
                        公司编号
                    </th>
                    <th>
                        英文名
                    </th>
                    <th>
                        中文名
                    </th>
                    <th>
                        月份
                    </th>
                    <th>
                        日期
                    </th>
                    <th>
                        管理
                    </th>
                    <th>
                        指派
                    </th>
                </tr>
                <tr runat="server" id="itemPlaceHolder">
                </tr>
            </table>
        </LayoutTemplate>
        <ItemTemplate>
            <tr>
                <td>
                    <asp:Label runat="server" ID="Label1" Text='<%# Eval("CompanyID")%>'></asp:Label>
                </td>
                <td>
                    <asp:HyperLink runat="server" Text='<%# Eval("EnglishName")%>' ID="HyperLink1" NavigateUrl='<%# Eval("CompanySerialNumber","~/Company/CompanyInfo.aspx?ID={0}")%>'></asp:HyperLink>
                </td>
                <td>
                    <asp:Label runat="server" ID="Label3" Text='<%# Eval("ChineseName")%>'></asp:Label>
                </td>
                <td>
                    <asp:Label runat="server" ID="Label4" Text='<%# Eval("auditmonth")%>'></asp:Label>
                </td>
                <td>
                    <asp:Label runat="server" ID="Label5" Text='<%# Eval("auditday")%>'></asp:Label>
                </td>
                <td>
                    <asp:LinkButton runat="server" Text="无效数据" ID="MarkIneffective" OnCommand="MarkIneffective_OnCommand"
                        CommandArgument='<%# Eval("companySerialNumber")%>' OnClientClick="return confirm('您确认要标记该公司为无效数据吗？');"></asp:LinkButton>
                    |
                    <asp:HyperLink runat="server" Text="修改数据" ID="HyperLink2" NavigateUrl='<%# Eval("CompanySerialNumber","~/Company/EditCompany.aspx?ID={0}")%>'></asp:HyperLink>
                </td>
                <td>
                    <asp:LinkButton ID="DesignateOwner" runat="server" Text="派给原分行" OnCommand="DesignateOwner_OnCommand"
                        CommandArgument='<%# Eval("companySerialNumber")%>'></asp:LinkButton>
                </td>
            </tr>
        </ItemTemplate>
    </asp:ListView>
    <asp:DataPager ID="DataPager1" runat="server" PagedControlID="ListView1" PageSize="20">
        <Fields>
            <asp:NextPreviousPagerField ButtonType="Button" ShowFirstPageButton="True" ShowLastPageButton="True" />
        </Fields>
    </asp:DataPager>
    <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:KOONCRMDB %>"
        SelectCommand="Task_GetAllTasks" SelectCommandType="StoredProcedure">
        <SelectParameters>
            <asp:ControlParameter ControlID="AuditMonth" Name="month" 
                PropertyName="SelectedValue" Type="Int32" />
        </SelectParameters>
    </asp:SqlDataSource>
</asp:Content>
